FROM harbor.kekesoft.work:49103/library/keke-jdk8-maven-builder:latest AS builder
WORKDIR /app
ADD ./src  src/
ADD ./pom.xml pom.xml
RUN  mvn clean package -Dmaven.test.skip=true

FROM harbor.kekesoft.work:49103/library/keke-jdk8-runtime:latest
WORKDIR /app
COPY --from=builder /app/target/*.jar  /app/app.jar

EXPOSE 8080
CMD ["java", "-jar", "app.jar"]